

package com.hazelcast.internal.monitor;

import com.hazelcast.json.internal.JsonSerializable;

import java.util.List;

/**
 * Partition related statistics to be used by {@link MemberState}
 * implementations.
 */
public interface MemberPartitionState extends JsonSerializable {

    /**
     * Returns a list of owned partitions of the member.
     *
     * @return list of owned partitions of the member
     */
    List<Integer> getPartitions();

    /**
     * Returns whether member is safe for shutdown.
     *
     * @return {@code true} if member is safe for shutdown, {@code false} otherwise
     */
    boolean isMemberStateSafe();
}
